<?php
require_once("../connection.php");

$gp_name = mysql_real_escape_string($_POST['gp_name']);

$res = mysql_query("SELECT * FROM site_groups WHERE `name`='$gp_name' AND `del`!='1'");
if(!$res) echo  mysql_error();

if(mysql_numrows($res) == 0)
	echo "1";
else
	echo "0";
?>